<?php
declare(strict_types=1);

use Phinx\Migration\AbstractMigration;

final class RemoveEntityCodeIndexInTaskTable extends AbstractMigration
{
    public function up()
    {
        $this->table('task')->removeIndexByName('idx_project_id_entity_code')->save();
    }

    public function down()
    {
        $this->table('task')
            ->addIndex(['project_id', 'entity_code', 'step_category_id'], ['name' => 'idx_project_id_entity_code'])
            ->save();
    }
}
